package pl.enigmatic.util;

public class Exceptions {

	private Exceptions() {}

	public static String toString(final Exception ex) {
		final StringBuilder builder = new StringBuilder();
		builder.append(ex);
		final StackTraceElement[] trace = ex.getStackTrace();
		for (final StackTraceElement element : trace) {
			builder.append("\nat ");
			builder.append(element);
		}
		return builder.toString();
	}

}
